<template>
  <div ref="test" class="test">
    <h1 v-for="item in 100" :key="item">
      {{item}}
    </h1>
    <button @click="scrollTest()">scrollto</button>
  </div>
</template>

<script>
export default {
  methods: {
    scrollTest () {
      let test = document.querySelector('.test')
      console.log(test)
      test.scrollTo(0, 0)
    }
  }
}
</script>

<style lang="scss" scoped>
</style>
